package 
{
	import flash.display.Sprite;
	
	import org.tuio.osc.IOSCListener;
	import org.tuio.osc.OSCMessage;

	public class HarmonyOSCListener extends Sprite implements IOSCListener
	{
		//--------------------------------------------------------------------------
		//
		//  Class variables
		//
		//--------------------------------------------------------------------------
		
		//--------------------------------------------------------------------------
		//
		//  Variables
		//
		//--------------------------------------------------------------------------
		
		//--------------------------------------------------------------------------
		//
		//  Initialization
		//
		//--------------------------------------------------------------------------
		public function HarmonyOSCListener()
		{
		}
		//--------------------------------------------------------------------------
		//
		//  Properties
		//
		//--------------------------------------------------------------------------
		
		//--------------------------------------------------------------------------
		//
		//  Additional getters and setters
		//
		//--------------------------------------------------------------------------
		private var _app:IHarmonyApp;
		
		public function set app(val:IHarmonyApp):void
		{
			_app = val;
		}
		
		public function get app():IHarmonyApp
		{
			return _app;
		}
		//--------------------------------------------------------------------------
		//
		//  Methods
		//
		//--------------------------------------------------------------------------
		
		//--------------------------------------------------------------------------
		//
		//  API
		//
		//--------------------------------------------------------------------------
		
		//--------------------------------------------------------------------------
		//
		//  Eventhandling
		//
		//--------------------------------------------------------------------------
		public function acceptOSCMessage(oscmsg:OSCMessage):void
		{
			app.updateOSCData(oscmsg);
		}
		//--------------------------------------------------------------------------
		//
		//  Broadcasting
		//
		//--------------------------------------------------------------------------
	}
}